﻿<div class="modal-header">
    <b>Dunning Configuration</b>
</div>
<div class="modal-body">
    <div>
        <form name="dunform" crud-edit="dunning">
            <div class="row">
                <label for="CustomerNum" class="control-label col-md-3">Customer Num:</label>
                <div class="col-md-6">
                    <input type="text" id="CustomerNum" class="form-control" name="CustomerNum" ng-model="dunning.customerNum" readonly />
                </div>
            </div>
            <div class="row" style="height:10px"></div>
            <div class="row">
                <label for="legalEntity" class="control-labelh col-md-3">Legal Entity:</label>
                <div class="col-md-6">
                    <select id="legalEntity" class="form-control input-sm" ng-model="dunning.legalEntity"
                            ng-options="a.legalEntity as a.legalEntity for a in legallist"></select>
                </div>
            </div>
            <div class="row" style="height:10px"></div>
            <div class="row">
                <label for="FirstInterval" class="control-labelh col-md-3">First Interval:</label>
                <div class="col-md-6">
                    <input type="text" id="FirstInterval" class="form-control" name="FirstInterval" ng-model="dunning.firstInterval" ng-pattern="/^[0-9]{1,2}$/" required />
                </div>
                <label ng-show="dunform.FirstInterval.$error.pattern"><font color=red>数值设置在0-99之间</font></label>
            </div>
            <div class="row" style="height:10px"></div>
            <div class="row">
                <label for="SecondInterval" class="control-labelh col-md-3">Second Interval:</label>
                <div class="col-md-6">
                    <input type="text" id="SecondInterval" class="form-control" name="SecondInterval" ng-model="dunning.secondInterval" ng-pattern="/^[0-9]{1,2}$/" required />        
                </div>
                <label ng-show="dunform.SecondInterval.$error.pattern"><font color=red>数值设置在0-99之间</font></label>
            </div>
            <div class="row" style="height:10px"></div>
            <div class="row">
                <label for="PaymentTAT" class="control-labelh col-md-3">Payment TAT:</label>
                <div class="col-md-6">
                    <input type="text" id="PaymentTAT" class="form-control" name="PaymentTAT" ng-model="dunning.paymentTAT" ng-pattern="/^[0-9]{1,2}$/" required />
                </div>
                <label ng-show="dunform.PaymentTAT.$error.pattern"><font color=red>数值设置在0-99之间</font></label>
            </div>
            <div class="row" style="height:10px"></div>
            <div class="row">
                <label for="RiskInterval" class="control-labelh col-md-3">Risk Interval:</label>
                <div class="col-md-6">
                    <input type="text" id="RiskInterval" class="form-control" name="RiskInterval" ng-model="dunning.riskInterval" ng-pattern="/^[0-9]{1,2}$/" required />
                </div>
                <label ng-show="dunform.RiskInterval.$error.pattern"><font color=red>数值设置在0-99之间</font></label>
            </div>
            <div class="row" style="height:10px"></div>
            <div class="row">
                <label for="Description" class="control-labelh col-md-3">Description:</label>
                <div class="col-md-6">
                    <input type="text" id="Description" class="form-control" name="Description" ng-model="dunning.description" />
                </div>
            </div>
            <p></p>
            <!--<crud-buttons></crud-buttons>-->
            <button type="button" class="btn btn-primary save" ng-disabled="!canSave()" ng-click="updateConfig()">Save</button>
            <button type="button" class="btn btn-warning revert" ng-click="revertChanges()" ng-disabled="!canRevert()">Revert changes</button>
        </form>
    </div>
</div>
<div class="modal-footer">
    <div class="row">
        <button type="button" class="btn btn-primary" ng-click="closeCust()" style="float:right; margin-right:10px">
            Close
        </button>
    </div>
</div>